/**
 * 
 */
package mockapp;

import junit.framework.TestCase;

/**
 * @author Rodrigo Barbosa Lira
 *
 */
public class SampleClientAppImplTest extends TestCase {
	
	private SampleClientAppImpl app;

	@Override
	protected void setUp() throws Exception {
		app = new SampleClientAppImpl();
	}

	/**
	 * Test method for {@link mockapp.SampleClientAppImpl#onEvent1()}.
	 */
	public void testOnEvent1() {
		assertFalse(app.isVar());
		app.onEvent1();
		assertTrue(app.isVar());
	}

	/**
	 * Test method for {@link mockapp.SampleClientAppImpl#deuproblema(char)}.
	 */
	public void testOnEvent2() {
		assertTrue(app.getCh() == 0);
		app.deuproblema('a');
		assertTrue(app.getCh() == 'a');
	}

	/**
	 * Test method for {@link mockapp.SampleClientAppImpl#onEvent3(java.lang.String)}.
	 */
	public void testOnEvent3() {
		assertNull(app.getText());
		app.onEvent3("myText");
		assertEquals("myText", app.getText());
	}

}
